package com.allwees.bs.c.module.user.util;

import com.allwees.bs.c.common.auth.constant.AuthConstant;
import org.springframework.security.crypto.bcrypt.BCrypt;

public class UserUtil {

    public static boolean checkPassword(String password,String encodedPassword){
        return BCrypt.checkpw(password, encodedPassword);
    }

    public static boolean isDefaultPwd(String encodedPassword){
        return checkPassword(AuthConstant.DEFAULT_OAUTH_PASSWORD, encodedPassword);
    }
}
